<%@ page import="com.mastercard.Deal" %>



<div class="fieldcontain ${hasErrors(bean: dealInstance, field: 'category', 'error')} required">
	<label for="category">
		<g:message code="deal.category.label" default="Category" />
		<span class="required-indicator">*</span>
	</label>
	<g:select id="category" name="category.id" from="${com.mastercard.Category.list()}" optionKey="id" required="" value="${dealInstance?.category?.id}" class="many-to-one"/>
</div>

<div class="fieldcontain ${hasErrors(bean: dealInstance, field: 'description', 'error')} ">
	<label for="description">
		<g:message code="deal.description.label" default="Description" />
		
	</label>
	<g:textField name="description" value="${dealInstance?.description}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: dealInstance, field: 'merchant', 'error')} required">
	<label for="merchant">
		<g:message code="deal.merchant.label" default="Merchant" />
		<span class="required-indicator">*</span>
	</label>
	<g:select id="merchant" name="merchant.id" from="${com.mastercard.Merchant.list()}" optionKey="id" required="" value="${dealInstance?.merchant?.id}" class="many-to-one"/>
</div>

<div class="fieldcontain ${hasErrors(bean: dealInstance, field: 'name', 'error')} ">
	<label for="name">
		<g:message code="deal.name.label" default="Name" />
		
	</label>
	<g:textField name="name" value="${dealInstance?.name}"/>
</div>

